#{extends 'logged_user.html' /}
#{set title:'Your Requests' /}
<h3>My Request</h3>
#{if requests}
<table style="width:92%">
  <tr>
    <th>Title</th>
    <th>Valid Until</th>
    <th colspan="2" style="text-align: center">Actions</th>
  </tr>
  #{list items:requests, as:'request'}
  <tr>
    <!-- <td><a href="@{Requests.showDetails(request.id)}">${request.title}</td> --> 
    <td>${request.title}</td>
    <td>${request.endDate.format('dd MMMM yyyy')}</td>
    <td><a href="@{Requests.showDetails(request.id)}">Show</a></td>
    <td><a href="@{Requests.edit(request.id)}">Edit</a></td>
  </tr>
</a>
#{/list}
</table>
#{/if}
#{else}
<p>Currently you have no requests.</p>
#{/else}
